package com.enation.app.shop.front.policyInsurance.service;

import com.enation.app.shop.core.goods.model.Cat;
import com.enation.app.shop.core.goods.model.Goods;
import com.enation.app.shop.core.goods.model.Product;
import com.enation.framework.database.Page;

import java.util.List;
import java.util.Map;

/**
 * 保险管理接口
 */
public interface InpolicyMapper {
    /**
     * 获取保险列表
     */
    Page getAllInspolicy(Map inPolicyMap, Integer page, Integer pageSize, String other, String order);    /**
     *  根据关键字查看保险详情
     */
    public int getInspolicyByNum(Integer goods_id);
    /**
     * 添加保险
     * @param goods
     */
    public int addGoods(Goods goods,Product product);

    /**
     * 添加保险的时候更新product表
     * @param product
     * @return
     */
    public int addProduct(Product product);
    /**
     * 编辑保险
     * @param goods
     * @return
     */
    public boolean updateGoods(Goods goods,Product product);
    /**
     *删除保险
     */
    public int delGoods(Integer goods_id);

    List<Cat> getInPolicyCat();
}
